using System;
using UnityEngine;

[CreateAssetMenu(fileName = "CircleTransitionOnExit", menuName = "Asset/LoadSceneScreenFX/CircleTransitionOnExit")]
public class CircleTransitionOnExit : CommandLogicSOBase
{
    protected override void OnExecute(Action doneCB, object param = null)
    {
        if (param == null)
        {
            GameRoot.Instance.uIService.PopWindow<CircleTransitionSceneWindow>().PlayTransition(false, 0.8f, doneCB);
        }
        else
        {
            GameRoot.Instance.uIService.PopWindow<CircleTransitionSceneWindow>().PlayTransition(false, (int)param, doneCB);
        }
    }
}
